package mt.client.GUI;

import java.awt.BorderLayout;
import java.awt.EventQueue;

import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;
import com.jgoodies.forms.layout.FormLayout;
import com.jgoodies.forms.layout.ColumnSpec;
import com.jgoodies.forms.layout.RowSpec;
import com.jgoodies.forms.factories.FormFactory;
import javax.swing.JLabel;
import javax.swing.JComboBox;
import javax.swing.JTextField;
import javax.swing.JButton;

public class SpontaneousOrderGUI extends JFrame {

	private JPanel contentPane;
	private JTextField textField;
	private JTextField textField_1;

	/**
	 * Launch the application.
	 */
	public static void main(String[] args) {
		EventQueue.invokeLater(new Runnable() {
			public void run() {
				try {
					SpontaneousOrderGUI frame = new SpontaneousOrderGUI();
					frame.setVisible(true);
				} catch (Exception e) {
					e.printStackTrace();
				}
			}
		});
	}

	/**
	 * Create the frame.
	 */
	public SpontaneousOrderGUI() {
		setTitle("Spontaneous Order");
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		setBounds(100, 100, 449, 193);
		contentPane = new JPanel();
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		setContentPane(contentPane);
		contentPane.setLayout(new FormLayout(new ColumnSpec[] {
				FormFactory.RELATED_GAP_COLSPEC,
				FormFactory.DEFAULT_COLSPEC,
				FormFactory.RELATED_GAP_COLSPEC,
				ColumnSpec.decode("default:grow"),},
			new RowSpec[] {
				FormFactory.RELATED_GAP_ROWSPEC,
				FormFactory.DEFAULT_ROWSPEC,
				FormFactory.RELATED_GAP_ROWSPEC,
				FormFactory.DEFAULT_ROWSPEC,
				FormFactory.RELATED_GAP_ROWSPEC,
				FormFactory.DEFAULT_ROWSPEC,
				FormFactory.RELATED_GAP_ROWSPEC,
				FormFactory.DEFAULT_ROWSPEC,
				FormFactory.RELATED_GAP_ROWSPEC,
				FormFactory.DEFAULT_ROWSPEC,
				FormFactory.RELATED_GAP_ROWSPEC,
				FormFactory.DEFAULT_ROWSPEC,}));
		
		JLabel lblStock = new JLabel("Stock");
		contentPane.add(lblStock, "2, 2, default, center");
		
		JLabel lblNumberOfUnits = new JLabel("Number of Units");
		contentPane.add(lblNumberOfUnits, "2, 4, left, center");
		
		JComboBox comboBox = new JComboBox();
		contentPane.add(comboBox, "4, 2, fill, default");
		
		textField = new JTextField();
		contentPane.add(textField, "4, 4, fill, default");
		textField.setColumns(10);
		
		JLabel lblPriceunit = new JLabel("Price/Unit (€)");
		contentPane.add(lblPriceunit, "2, 6, left, center");
		
		textField_1 = new JTextField();
		contentPane.add(textField_1, "4, 6, fill, default");
		textField_1.setColumns(10);
		
		JButton btnPlaceOrder = new JButton("Place Order");
		contentPane.add(btnPlaceOrder, "2, 10, left, center");
		
		
	}

}
